/**
 * Created by rongyao on 2017/10/18.
 */
var mongoose = require('mongoose');
var mongoosePaginate = require('mongoose-paginate');

var newsSchema = new mongoose.Schema({
	title:String,
	content:String,
	cateId:String,
	commentCount:String,
	address:String,
	pic:Object,
	date:{type:Date,default:Date.now}
});
newsSchema.plugin(mongoosePaginate);

module.exports = mongoose.model('News',newsSchema,'news'); // Model.paginate()